const {ccclass, property} = cc._decorator;

@ccclass
export default class StartScene extends cc.Component {

    @property(cc.Button)
    playBtn: cc.Button = null;

    start () {
        this.playBtn.node.on('click',this.onPlayBtnClicked.bind(this));     
        this.playBtn.node.on('click',this.onPlayBtnClicked,this);     
    }

    onPlayBtnClicked() {
        cc.director.loadScene("GameScene",()=>{
            console.log("GameScene loaded");
        });
    }
}
